projects
/
cargo.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8bff726
)
Add test for having lto enabled while having a build script
author
Mikko Perttunen
<cyndis@kapsi.fi>
Mon, 2 Mar 2015 17:09:05 +0000
(19:09 +0200)
committer
Mikko Perttunen
<cyndis@kapsi.fi>
Mon, 2 Mar 2015 17:14:50 +0000
(19:14 +0200)
tests/test_cargo_compile_custom_build.rs
patch
|
blob
|
history
diff --git
a/tests/test_cargo_compile_custom_build.rs
b/tests/test_cargo_compile_custom_build.rs
index 5ef4c238fc47aac5cf8a3eaeaa9f14bd345788a8..90b617cc28fe4a4639a3a4060e8c38e6d0c0d57a 100644
(file)
--- a/
tests/test_cargo_compile_custom_build.rs
+++ b/
tests/test_cargo_compile_custom_build.rs
@@
-1099,3
+1099,24
@@
test!(profile_and_opt_level_set_correctly {
assert_that(build.cargo_process("bench"),
execs().with_status(0));
});
+
+test!(build_script_with_lto {
+ let build = project("builder")
+ .file("Cargo.toml", r#"
+ [package]
+ name = "builder"
+ version = "0.0.1"
+ authors = []
+ build = "build.rs"
+
+ [profile.dev]
+ lto = true
+ "#)
+ .file("src/lib.rs", "")
+ .file("build.rs", r#"
+ fn main() {
+ }
+ "#);
+ assert_that(build.cargo_process("build"),
+ execs().with_status(0));
+});